package adsi.domain;

import org.json.*;

public class Maintenance implements JSONString {

    private long ID;
    private String description;
    private int duration;

    public Maintenance() {
        //values of -1 means no valid value.
        ID = -1;
        description = null;
        duration = -1;
    }
    
    public Maintenance(long ID, String description, int duration) {
        //values of -1 means no valid value.
        this.ID = ID;
        this.description = description;
        this.duration = duration;
    }

    public long getID() {
        return ID;
    }

    public void setID(long ID) {
        this.ID = ID;
    }

    public String getDescription() {
        return description;
    }

    public int getDuration() {
        return duration;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public void setDuration(int duration) {
        this.duration = duration;
    }

    public String toJSONString() {
        return "{\"id\" : \"" + ID + "\", \"description\" : \"" + description + "\", \"duration\" : \"" + duration + "\"}";
    }
}
